package com.bob.debt.controller;

import com.bob.debt.callback.DCOTCServerMsgCallBack;
import com.chinabond.dcotc.sdk.pojo.DCOTCMessage;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class HelloController {

    @Resource
    private DCOTCServerMsgCallBack dcotcServerMsgCallBack;

    @RequestMapping("/hello.do")
    public String hello(String name) {
        DCOTCMessage dcotcMessage = new DCOTCMessage();
        dcotcMessage.setMsgType("otcs.991.001.02");
        dcotcServerMsgCallBack.onMessage(dcotcMessage);
        return "Hello" + name;
    }


}
